<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>

        * {
            padding: 0;
            margin: 0;
        }

        .wrapper {
            width: 300px;
            height: 200px;
            border: 1px solid black;
            display: flex;
            align-items: center;
            
        }

        .item {
            flex: 1 1 auto;
            height: 30px;
            text-align: center;
            line-height: 30px;
            font-size: 20px;
            color: #f20;
            border-radius: 5px;
        }

        .item:hover {
            color: #fff;
            background-color: #f20;
        }




    </style>
</head>
<body>
    <div class="wrapper">
        <div class="item">天猫</div>
        <div class="item">淘宝</div>
        <div class="item">聚划算</div>
        <div class="item">京东</div>
    </div>
</body>
</html>